package oa.hleast.xswl.service;


import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import oa.hleast.xswl.pojo.domain.SysDict;
import oa.hleast.xswl.pojo.domain.UmsMember;
import oa.hleast.xswl.pojo.dto.AuthMemberDTO;
import oa.hleast.xswl.pojo.dto.ManagerUserDTO;
import oa.hleast.xswl.pojo.dto.MemberDataDTO;
import oa.hleast.xswl.pojo.dto.UmsUserDto;

import java.util.List;

public interface IUmsUserService extends IService<UmsMember> {

    IPage<UmsMember> list(Page<UmsMember> page, UmsMember user);

    MemberDataDTO getMemberByToken(Long userId);

    List<SysDict> getGenderDict();

    ManagerUserDTO getBaseMember(Long userId);

    AuthMemberDTO getUserByOpenid(String openid);

    AuthMemberDTO getUserByCustUserId(String custUserId);

    List<UmsMember> findInterviewer();

    String sendSms(String phone);

    UmsUserDto getUserDtoById(Long userId);

    AuthMemberDTO getUserByZjfwwUserId(String zjfwwUserId);

    /**
     * 根据身份证号获取用户信息
     *
     * @param idCardNum 身份证号
     * @return 用户信息
     */
    AuthMemberDTO getUserByIdCardNum(String idCardNum);

    Long getPoint(Long userId);

    Long getBalance(Long memberId);

    boolean deductBalance(Long userId, Long payAmount);

    boolean updatePoint(Long point, Integer code);
}
